package cc.eddic.practice.spring.domain;

import cc.eddic.practice.spring.Gender;
import cc.eddic.practice.spring.jpa.BaseEntity;
import lombok.*;
import org.springframework.data.jpa.domain.support.AuditingEntityListener;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.EntityListeners;
import javax.persistence.Table;

@Entity
@EntityListeners(AuditingEntityListener.class)
@Table(name = "t_student")
@Builder
@Getter
@ToString
@NoArgsConstructor
@AllArgsConstructor
@EqualsAndHashCode(callSuper = true)
public class Student extends BaseEntity {
    @Column(length = 50)
    private String name;

    private Gender gender;

    @Column(length = 50)
    private String major;
}
